import { createApp } from "vue";
import App from "./App.vue";
import "./permisstion"

// 关键！必须导入mock文件，否则mock功能不会生效
import "./mock/user";
import router from "./router";
// 导入Element Plus和其样式
import ElementPlus from "element-plus";
import "element-plus/dist/index.css";
// 导入pinia
import pinia from './store'
// 导入Element Plus所有图标
import * as ElementPlusIconsVue from '@element-plus/icons-vue'

const app = createApp(App);
// 注册Element Plus所有图标
for (const [key, component] of Object.entries(ElementPlusIconsVue)) {
  app.component(key, component)
}
app.use(router);
// 注册Element Plus插件
app.use(ElementPlus);
app.use(pinia)
app.mount("#app");